﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using SistemaHospital.HospitalServiceReference;
using SistemaHospital.Model;

namespace SistemaHospital.Views
{
    /// <summary>
    /// Interaction logic for RegistrarHospitalView.xaml
    /// </summary>
    public partial class RegistrarHospitalView : UserControl
    {
        public RegistrarHospitalView()
        {
            InitializeComponent();
        }

        private void btnRegistrar_Click(object sender, RoutedEventArgs e)
        {
            HospitalServicesClient serviceClient = new HospitalServicesClient();

            string codigo = serviceClient.RegistrarHospital("Macabeos", "Contra");

            Properties.Settings.Default.CodigoDelHospital = codigo;
            Properties.Settings.Default.Save();
        }
    }
}
